package edu.tongji.structureplayer.structure
{
    public class KeyPoint extends BaseStructure
    {
        private var _position:Number;
        private var _strength:Number;
        private var _direction:Number;
        
        public function KeyPoint(name:String, position:Number, strength:Number, direction:Number)
        {
            super(name);
            _position = position;
            _strength = strength;
            _direction = direction;
        }
        
        public function overlap(position:Number, stength:Number, direction:Number):Boolean
        {
            if (_position!=position || _strength!=strength || _direction!=direction)
                return false;
            return true;
        }

        public function get position():Number
        {
            return _position;
        }

        public function set position(value:Number):void
        {
            _position = value;
        }

        public function get strength():Number
        {
            return _strength;
        }

        public function set strength(value:Number):void
        {
            _strength = value;
        }

        public function get direction():Number
        {
            return _direction;
        }

        public function set direction(value:Number):void
        {
            _direction = value;
        }
        
        public function debugPrint():void
        {
            trace ("KeyPoint " + name + "(" + _position + ", " + _strength + ", "
                + _direction + ")");
        }


    }
}